<?xml version="1.0" encoding="UTF-8"?>
<!--
To change this license header, choose License Headers in Project Properties.
To change this template file, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://xmlns.jcp.org/jsf/core">
    <h:head>
        <title>Facelet Title</title>
    </h:head>
    <h:body>
           <h:form>
            <p:commandButton value="Update you profile" action="#{userBean.updateProfile()}" />
            <p:commandButton value="Logout" action="#{loginBean.logout()}" />

             </h:form>
        <p:panel header="Your Profile">
         
            <p:panelGrid columns="2">
                    <f:facet name="header">
                        <p:graphicImage url="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQP7DGq7uBcqvNh_XEVX-9mhEfp9jAN8QKFs0KBsSu8bqZeunbP" />
                    </f:facet>

                    <h:outputText value="Name:" />
                    <h:outputText value="#{userBean.user.name}" />

                    <h:outputText value="Surname:" />
                    <h:outputText value="#{userBean.user.surname}" />

                    <h:outputText value="Email:" />
                    <h:outputText value="#{userBean.user.email}" />
             </p:panelGrid>
       
        </p:panel>
    </h:body>
</html>

